﻿// Action script...

// [Initial MovieClip Action of sprite 400]
#initclip 5
class gs.OverwriteManager
{
    static var mode, enabled;
    function OverwriteManager()
    {
    } // End of the function
    static function init($mode)
    {
        if (gs.TweenLite.version < 8.140000)
        {
            trace ("TweenLite warning: Your TweenLite class needs to be updated to work with OverwriteManager (or you may need to clear your ASO files). Please download and install the latest version from http://www.tweenlite.com.");
        } // end if
        gs.TweenLite.overwriteManager = gs.OverwriteManager;
        mode = $mode == undefined ? (2) : ($mode);
        enabled = true;
        return (gs.OverwriteManager.mode);
    } // End of the function
    static function manageOverwrites($instance, $objTweens)
    {
        var _loc5 = $instance.vars;
        var _loc9 = _loc5.overwrite == undefined ? (gs.OverwriteManager.mode) : (Number(_loc5.overwrite));
        if (_loc9 < 2)
        {
            return;
        } // end if
        var _loc6 = $instance.startTime;
        var _loc1 = [];
        var _loc3;
        var _loc8;
        for (var _loc8 in $objTweens)
        {
            if (_loc8 != "info" && $objTweens[_loc8] != $instance && $objTweens[_loc8].startTime <= _loc6)
            {
                _loc1[_loc1.length] = _loc8;
            } // end if
        } // end of for...in
        if (_loc1.length == 0)
        {
            return;
        } // end if
        if (_loc9 == gs.OverwriteManager.AUTO)
        {
            var _loc4 = {};
            for (var _loc8 in _loc5)
            {
                if (_loc8 == "ease" || _loc8 == "delay" || _loc8 == "overwrite" || _loc8 == "onComplete" || _loc8 == "onCompleteParams" || _loc8 == "runBackwards" || _loc8 == "persist" || _loc8 == "onUpdate" || _loc8 == "onUpdateParams" || _loc8 == "timeScale" || _loc8 == "onStart" || _loc8 == "onStartParams" || _loc8 == "renderOnStart" || _loc8 == "proxiedEase" || _loc8 == "easeParams" || _loc8 == "onCompleteAll" || _loc8 == "onCompleteAllParams" || _loc8 == "yoyo" || _loc8 == "loop")
                {
                    continue;
                } // end if
                _loc4[_loc8] = 1;
            } // end of for...in
            for (var _loc3 = _loc1.length - 1; _loc3 > -1; --_loc3)
            {
                $objTweens[_loc1[_loc3]].killVars(_loc4);
            } // end of for
        }
        else
        {
            for (var _loc3 = _loc1.length - 1; _loc3 > -1; --_loc3)
            {
                delete $objTweens[_loc1[_loc3]];
            } // end of for
        } // end else if
    } // End of the function
    static function killVars($killVars, $vars, $tweens, $subTweens, $filters)
    {
        var _loc1;
        for (var _loc1 = $subTweens.length - 1; _loc1 > -1; --_loc1)
        {
            if ($killVars[$subTweens[_loc1].name] != undefined)
            {
                $subTweens.splice(_loc1, 1);
            } // end if
        } // end of for
        for (var _loc1 = $tweens.length - 1; _loc1 > -1; --_loc1)
        {
            if ($killVars[$tweens[_loc1].name] != undefined)
            {
                $tweens.splice(_loc1, 1);
            } // end if
        } // end of for
        for (var _loc1 = $filters.length - 1; _loc1 > -1; --_loc1)
        {
            if ($killVars[$filters[_loc1].name] != undefined)
            {
                $filters.splice(_loc1, 1);
            } // end if
        } // end of for
        for (var _loc6 in $killVars)
        {
            delete $vars[_loc6];
        } // end of for...in
    } // End of the function
    static var version = 0.961000;
    static var NONE = 0;
    static var ALL = 1;
    static var AUTO = 2;
    static var CONCURRENT = 3;
} // End of Class
#endinitclip
